]>
Commit | Line | Data |
---|---|---|
8280e301 | 1 | Summary: Older implementation of C++ interface to PostgreSQL |
b4af8a16 | 2 | Summary(pl.UTF-8): Starsza implementacja interfejsu C++ do PostgreSQL |
8280e301 JB |
3 | Name: libpq++ |
4 | Version: 4.0 | |
ee43fdc1 | 5 | Release: 5 |
8280e301 JB |
6 | License: BSD |
7 | Group: Libraries | |
9991e63b | 8 | Source0: https://ftp.postgresql.org/pub/projects/gborg/libpqpp/stable/%{name}-%{version}.tar.gz |
fc70410f | 9 | # Source0-md5: da71cb79ef45cef55f4bc97a33a0857d |
8280e301 | 10 | Patch0: %{name}-make.patch |
5c9ad409 | 11 | Patch1: %{name}-libdir.patch |
833684d7 | 12 | Patch2: include.patch |
9991e63b | 13 | URL: https://www.postgresql.org/docs/7.0/libpqplusplus.htm |
8e9b3e99 | 14 | BuildRequires: libstdc++-devel |
8280e301 | 15 | BuildRequires: postgresql-devel >= 7.3 |
f90ff45b | 16 | Provides: postgresql-c++ |
21a8da32 | 17 | Obsoletes: postgresql-c++ |
8280e301 JB |
18 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
19 | ||
20 | %description | |
21 | This package includes library for C++ interface to PostgreSQL. It's | |
22 | an older implementation, included with PostgreSQL up to 7.2.x. | |
23 | ||
33ff7718 | 24 | %description -l pl.UTF-8 |
8280e301 | 25 | Pakiet ten zawiera biblioteki dla interfejsu C++ do PostgreSQL. Jest |
33ff7718 | 26 | to starsza implementacja, dołączana do PostgreSQL-a aż do 7.2.x. |
8280e301 JB |
27 | |
28 | %package devel | |
29 | Summary: Older C++ interface to PostgreSQL - development part | |
b4af8a16 | 30 | Summary(pl.UTF-8): Starszy interfejs C++ do PostgreSQL - część programistyczna |
8280e301 | 31 | Group: Development/Libraries |
af67d3fc | 32 | Requires: %{name} = %{version}-%{release} |
21a8da32 | 33 | Requires: libstdc++-devel |
8280e301 | 34 | Requires: postgresql-devel |
f90ff45b | 35 | Provides: postgresql-c++-devel |
21a8da32 | 36 | Obsoletes: postgresql-c++-devel |
8280e301 JB |
37 | |
38 | %description devel | |
39 | This package includes header files for older C++ interface. | |
40 | ||
33ff7718 JR |
41 | %description devel -l pl.UTF-8 |
42 | Pakiet ten zawiera pliki nagłówkowe dla starszego interfejsu C++. | |
8280e301 JB |
43 | |
44 | %package static | |
45 | Summary: Older C++ interface to PostgreSQL - static libraries | |
b4af8a16 | 46 | Summary(pl.UTF-8): Starszy interfejs C++ do PostgreSQL - biblioteki statyczne |
8280e301 | 47 | Group: Development/Libraries |
af67d3fc | 48 | Requires: %{name}-devel = %{version}-%{release} |
f90ff45b | 49 | Provides: postgresql-c++-static |
21a8da32 | 50 | Obsoletes: postgresql-c++-static |
8280e301 JB |
51 | |
52 | %description static | |
53 | This package includes static library for older interface C++. | |
54 | ||
33ff7718 | 55 | %description static -l pl.UTF-8 |
8280e301 JB |
56 | Pakiet ten zawiera biblioteki statyczne dla starszego interfejsu C++. |
57 | ||
58 | %prep | |
59 | %setup -q | |
5c9ad409 | 60 | %patch0 -p1 |
61 | %patch1 -p0 | |
833684d7 | 62 | %patch2 -p1 |
8280e301 JB |
63 | |
64 | %build | |
65 | %{__make} static \ | |
5c9ad409 | 66 | POSTGRES_HOME=%{_prefix} \ |
67 | LIBDIR=%{_libdir} \ | |
8280e301 JB |
68 | CXX="%{__cxx}" \ |
69 | CXXFLAGS="%{rpmcflags} -Wall" | |
70 | ||
970a3774 | 71 | %{__rm} *.o |
8280e301 | 72 | %{__make} \ |
5c9ad409 | 73 | POSTGRES_HOME=%{_prefix} \ |
74 | LIBDIR=%{_libdir} \ | |
8280e301 | 75 | CXX="%{__cxx}" \ |
833684d7 WF |
76 | CXXFLAGS="%{rpmcflags} -Wall -fPIC" \ |
77 | LDFLAGS="%{rpmldflags}" | |
dadbde83 | 78 | |
8280e301 JB |
79 | %install |
80 | rm -rf $RPM_BUILD_ROOT | |
81 | install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} | |
82 | ||
83 | %{__make} install \ | |
84 | DESTDIR=$RPM_BUILD_ROOT \ | |
5c9ad409 | 85 | LIBDIR=%{_libdir} \ |
8280e301 JB |
86 | POSTGRES_HOME=%{_prefix} |
87 | ||
833684d7 WF |
88 | ln -sf libpq++.so.4.0 $RPM_BUILD_ROOT%{_libdir}/libpq++.so.4 |
89 | ||
8280e301 JB |
90 | install examples/*.* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} |
91 | ||
92 | %clean | |
93 | rm -rf $RPM_BUILD_ROOT | |
94 | ||
95 | %post -p /sbin/ldconfig | |
96 | %postun -p /sbin/ldconfig | |
97 | ||
98 | %files | |
99 | %defattr(644,root,root,755) | |
100 | %doc CHANGES README | |
970a3774 JB |
101 | %attr(755,root,root) %{_libdir}/libpq++.so.*.* |
102 | %attr(755,root,root) %ghost %{_libdir}/libpq++.so.4 | |
8280e301 JB |
103 | |
104 | %files devel | |
105 | %defattr(644,root,root,755) | |
106 | %doc docs/*.html | |
970a3774 JB |
107 | %attr(755,root,root) %{_libdir}/libpq++.so |
108 | %{_includedir}/libpq++.h | |
8280e301 JB |
109 | %{_includedir}/libpq++ |
110 | %{_examplesdir}/%{name}-%{version} | |
111 | ||
112 | %files static | |
113 | %defattr(644,root,root,755) | |
970a3774 | 114 | %{_libdir}/libpq++.a |